Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add detection for custom Linker #232

Merged
merged 10 commits into from
Aug 8, 2023

Conversation

abeimler
Copy link
Contributor

@abeimler abeimler commented Aug 6, 2023

  • Add test_linker_option for testing linker option
  • Add find_linker for detection 3rd-party linker

Linker

  • sold
  • mold
  • LLVM lld
  • GNU gold

Notes

Copy link
Owner

@aminya aminya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems gcc is failing on Ubuntu with

[5/7] Linking CXX executable Release/main
FAILED: Release/main 
: && /usr/bin/g++-13 -O3 -DNDEBUG -flto=auto -fno-fat-lto-objects -fuse-ld=lld -fsanitize=address,pointer-compare,pointer-subtract,undefined -Wall -Wextra -Wextra-semi -Wshadow -Wnon-virtual-dtor -Wold-style-cast -Wcast-align -Wunused -Woverloaded-virtual -Wpedantic -Wconversion -Wsign-conversion -Wnull-dereference -Wdouble-promotion -Wformat=2 -Wimplicit-fallthrough -Wmisleading-indentation -Wduplicated-cond -Wduplicated-branches -Wlogical-op -Wuseless-cast CMakeFiles/main.dir/Release/src/main/main.cpp.o -o Release/main  vcpkg_installed/x64-linux/lib/libfmt.a  --coverage && :
ld.lld: error: undefined symbol: main
>>> referenced by /usr/lib/gcc/x86_64-linux-gnu/13/../../../x86_64-linux-gnu/Scrt1.o:(_start)
collect2: error: ld returned 1 exit status

src/Utilities.cmake Outdated Show resolved Hide resolved
src/Utilities.cmake Outdated Show resolved Hide resolved
aminya
aminya previously approved these changes Aug 8, 2023
@aminya aminya merged commit 8dd8a5d into aminya:main Aug 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants